package com.atguigu.exer.servlect01;

import jakarta.servlet.ServletException;
import jakarta.servlet.http.HttpServlet;
import jakarta.servlet.http.HttpServletRequest;
import jakarta.servlet.http.HttpServletResponse;

import java.io.IOException;

/**
 * @version 1.0
 * @Author 马冰
 * @Date 2024/12/9 21:27
 * @注释
 */
public class HPServlet extends HttpServlet {
    @Override
    protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {
        System.out.println("PathServlet doGet 请求收到了");

        resp.getWriter().println("HPServlet doGet Response Success");
    }

    @Override
    protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {
        System.out.println("PathServlet doPost 请求收到了");

        resp.getWriter().println("HPServlet doPost Response Success");
    }
}
